Optimal. Leaf size=160 \[ -\frac {3 x \cosh \left (a+b x^2\right )}{8 b}+\frac {x \cosh \left (3 a+3 b x^2\right )}{24 b}+\frac {3 e^{-a} \sqrt {\pi } \text {Erf}\left (\sqrt {b} x\right )}{32 b^{3/2}}-\frac {e^{-3 a} \sqrt {\frac {\pi }{3}} \text {Erf}\left (\sqrt {3} \sqrt {b} x\right )}{96 b^{3/2}}+\frac {3 e^a \sqrt {\pi } \text {Erfi}\left (\sqrt {b} x\right )}{32 b^{3/2}}-\frac {e^{3 a} \sqrt {\frac {\pi }{3}} \text {Erfi}\left (\sqrt {3} \sqrt {b} x\right )}{96 b^{3/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.11, antiderivative size = 160, normalized size of antiderivative = 1.00, number of steps
used = 10, number of rules used = 5, integrand size = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.357, Rules used = {5448, 5432,
5407, 2235, 2236} \begin {gather*} \frac {3 \sqrt {\pi } e^{-a} \text {Erf}\left (\sqrt {b} x\right )}{32 b^{3/2}}-\frac {\sqrt {\frac {\pi }{3}} e^{-3 a} \text {Erf}\left (\sqrt {3} \sqrt {b} x\right )}{96 b^{3/2}}+\frac {3 \sqrt {\pi } e^a \text {Erfi}\left (\sqrt {b} x\right )}{32 b^{3/2}}-\frac {\sqrt {\frac {\pi }{3}} e^{3 a} \text {Erfi}\left (\sqrt {3} \sqrt {b} x\right )}{96 b^{3/2}}-\frac {3 x \cosh \left (a+b x^2\right )}{8 b}+\frac {x \cosh \left (3 a+3 b x^2\right )}{24 b} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 2235
Rule 2236
Rule 5407
Rule 5432
Rule 5448
Rubi steps
\begin {align*} \int x^2 \sinh ^3\left (a+b x^2\right ) \, dx &=\int \left (-\frac {3}{4} x^2 \sinh \left (a+b x^2\right )+\frac {1}{4} x^2 \sinh \left (3 a+3 b x^2\right )\right ) \, dx\\ &=\frac {1}{4} \int x^2 \sinh \left (3 a+3 b x^2\right ) \, dx-\frac {3}{4} \int x^2 \sinh \left (a+b x^2\right ) \, dx\\ &=-\frac {3 x \cosh \left (a+b x^2\right )}{8 b}+\frac {x \cosh \left (3 a+3 b x^2\right )}{24 b}-\frac {\int \cosh \left (3 a+3 b x^2\right ) \, dx}{24 b}+\frac {3 \int \cosh \left (a+b x^2\right ) \, dx}{8 b}\\ &=-\frac {3 x \cosh \left (a+b x^2\right )}{8 b}+\frac {x \cosh \left (3 a+3 b x^2\right )}{24 b}-\frac {\int e^{-3 a-3 b x^2} \, dx}{48 b}-\frac {\int e^{3 a+3 b x^2} \, dx}{48 b}+\frac {3 \int e^{-a-b x^2} \, dx}{16 b}+\frac {3 \int e^{a+b x^2} \, dx}{16 b}\\ &=-\frac {3 x \cosh \left (a+b x^2\right )}{8 b}+\frac {x \cosh \left (3 a+3 b x^2\right )}{24 b}+\frac {3 e^{-a} \sqrt {\pi } \text {erf}\left (\sqrt {b} x\right )}{32 b^{3/2}}-\frac {e^{-3 a} \sqrt {\frac {\pi }{3}} \text {erf}\left (\sqrt {3} \sqrt {b} x\right )}{96 b^{3/2}}+\frac {3 e^a \sqrt {\pi } \text {erfi}\left (\sqrt {b} x\right )}{32 b^{3/2}}-\frac {e^{3 a} \sqrt {\frac {\pi }{3}} \text {erfi}\left (\sqrt {3} \sqrt {b} x\right )}{96 b^{3/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.21, size = 184, normalized size = 1.15 \begin {gather*} \frac {-108 \sqrt {b} x \cosh \left (a+b x^2\right )+12 \sqrt {b} x \cosh \left (3 \left (a+b x^2\right )\right )+27 \sqrt {\pi } \cosh (a) \text {Erfi}\left (\sqrt {b} x\right )-\sqrt {3 \pi } \cosh (3 a) \text {Erfi}\left (\sqrt {3} \sqrt {b} x\right )+27 \sqrt {\pi } \text {Erf}\left (\sqrt {b} x\right ) (\cosh (a)-\sinh (a))+27 \sqrt {\pi } \text {Erfi}\left (\sqrt {b} x\right ) \sinh (a)-\sqrt {3 \pi } \text {Erfi}\left (\sqrt {3} \sqrt {b} x\right ) \sinh (3 a)+\sqrt {3 \pi } \text {Erf}\left (\sqrt {3} \sqrt {b} x\right ) (-\cosh (3 a)+\sinh (3 a))}{288 b^{3/2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 1.20, size = 157, normalized size = 0.98
method | result | size |
risch | \(\frac {{\mathrm e}^{-3 a} x \,{\mathrm e}^{-3 x^{2} b}}{48 b}-\frac {{\mathrm e}^{-3 a} \sqrt {\pi }\, \sqrt {3}\, \erf \left (x \sqrt {3}\, \sqrt {b}\right )}{288 b^{\frac {3}{2}}}-\frac {3 \,{\mathrm e}^{-a} x \,{\mathrm e}^{-x^{2} b}}{16 b}+\frac {3 \,{\mathrm e}^{-a} \sqrt {\pi }\, \erf \left (x \sqrt {b}\right )}{32 b^{\frac {3}{2}}}-\frac {3 \,{\mathrm e}^{a} {\mathrm e}^{x^{2} b} x}{16 b}+\frac {3 \,{\mathrm e}^{a} \sqrt {\pi }\, \erf \left (\sqrt {-b}\, x \right )}{32 b \sqrt {-b}}+\frac {{\mathrm e}^{3 a} x \,{\mathrm e}^{3 x^{2} b}}{48 b}-\frac {{\mathrm e}^{3 a} \sqrt {\pi }\, \erf \left (\sqrt {-3 b}\, x \right )}{96 b \sqrt {-3 b}}\) | \(157\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.48, size = 162, normalized size = 1.01 \begin {gather*} -\frac {\sqrt {3} \sqrt {\pi } \operatorname {erf}\left (\sqrt {3} \sqrt {-b} x\right ) e^{\left (3 \, a\right )}}{288 \, \sqrt {-b} b} - \frac {\sqrt {3} \sqrt {\pi } \operatorname {erf}\left (\sqrt {3} \sqrt {b} x\right ) e^{\left (-3 \, a\right )}}{288 \, b^{\frac {3}{2}}} + \frac {x e^{\left (3 \, b x^{2} + 3 \, a\right )}}{48 \, b} - \frac {3 \, x e^{\left (b x^{2} + a\right )}}{16 \, b} - \frac {3 \, x e^{\left (-b x^{2} - a\right )}}{16 \, b} + \frac {x e^{\left (-3 \, b x^{2} - 3 \, a\right )}}{48 \, b} + \frac {3 \, \sqrt {\pi } \operatorname {erf}\left (\sqrt {b} x\right ) e^{\left (-a\right )}}{32 \, b^{\frac {3}{2}}} + \frac {3 \, \sqrt {\pi } \operatorname {erf}\left (\sqrt {-b} x\right ) e^{a}}{32 \, \sqrt {-b} b} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 904 vs.
\(2 (114) = 228\).
time = 0.36, size = 904, normalized size = 5.65 \begin {gather*} \frac {6 \, b x \cosh \left (b x^{2} + a\right )^{6} + 36 \, b x \cosh \left (b x^{2} + a\right ) \sinh \left (b x^{2} + a\right )^{5} + 6 \, b x \sinh \left (b x^{2} + a\right )^{6} - 54 \, b x \cosh \left (b x^{2} + a\right )^{4} + 18 \, {\left (5 \, b x \cosh \left (b x^{2} + a\right )^{2} - 3 \, b x\right )} \sinh \left (b x^{2} + a\right )^{4} - 54 \, b x \cosh \left (b x^{2} + a\right )^{2} + 24 \, {\left (5 \, b x \cosh \left (b x^{2} + a\right )^{3} - 9 \, b x \cosh \left (b x^{2} + a\right )\right )} \sinh \left (b x^{2} + a\right )^{3} + \sqrt {3} \sqrt {\pi } {\left (\cosh \left (b x^{2} + a\right )^{3} \cosh \left (3 \, a\right ) + {\left (\cosh \left (3 \, a\right ) + \sinh \left (3 \, a\right )\right )} \sinh \left (b x^{2} + a\right )^{3} + \cosh \left (b x^{2} + a\right )^{3} \sinh \left (3 \, a\right ) + 3 \, {\left (\cosh \left (b x^{2} + a\right ) \cosh \left (3 \, a\right ) + \cosh \left (b x^{2} + a\right ) \sinh \left (3 \, a\right )\right )} \sinh \left (b x^{2} + a\right )^{2} + 3 \, {\left (\cosh \left (b x^{2} + a\right )^{2} \cosh \left (3 \, a\right ) + \cosh \left (b x^{2} + a\right )^{2} \sinh \left (3 \, a\right )\right )} \sinh \left (b x^{2} + a\right )\right )} \sqrt {-b} \operatorname {erf}\left (\sqrt {3} \sqrt {-b} x\right ) - \sqrt {3} \sqrt {\pi } {\left (\cosh \left (b x^{2} + a\right )^{3} \cosh \left (3 \, a\right ) + {\left (\cosh \left (3 \, a\right ) - \sinh \left (3 \, a\right )\right )} \sinh \left (b x^{2} + a\right )^{3} - \cosh \left (b x^{2} + a\right )^{3} \sinh \left (3 \, a\right ) + 3 \, {\left (\cosh \left (b x^{2} + a\right ) \cosh \left (3 \, a\right ) - \cosh \left (b x^{2} + a\right ) \sinh \left (3 \, a\right )\right )} \sinh \left (b x^{2} + a\right )^{2} + 3 \, {\left (\cosh \left (b x^{2} + a\right )^{2} \cosh \left (3 \, a\right ) - \cosh \left (b x^{2} + a\right )^{2} \sinh \left (3 \, a\right )\right )} \sinh \left (b x^{2} + a\right )\right )} \sqrt {b} \operatorname {erf}\left (\sqrt {3} \sqrt {b} x\right ) - 27 \, \sqrt {\pi } {\left (\cosh \left (b x^{2} + a\right )^{3} \cosh \left (a\right ) + {\left (\cosh \left (a\right ) + \sinh \left (a\right )\right )} \sinh \left (b x^{2} + a\right )^{3} + \cosh \left (b x^{2} + a\right )^{3} \sinh \left (a\right ) + 3 \, {\left (\cosh \left (b x^{2} + a\right ) \cosh \left (a\right ) + \cosh \left (b x^{2} + a\right ) \sinh \left (a\right )\right )} \sinh \left (b x^{2} + a\right )^{2} + 3 \, {\left (\cosh \left (b x^{2} + a\right )^{2} \cosh \left (a\right ) + \cosh \left (b x^{2} + a\right )^{2} \sinh \left (a\right )\right )} \sinh \left (b x^{2} + a\right )\right )} \sqrt {-b} \operatorname {erf}\left (\sqrt {-b} x\right ) + 27 \, \sqrt {\pi } {\left (\cosh \left (b x^{2} + a\right )^{3} \cosh \left (a\right ) + {\left (\cosh \left (a\right ) - \sinh \left (a\right )\right )} \sinh \left (b x^{2} + a\right )^{3} - \cosh \left (b x^{2} + a\right )^{3} \sinh \left (a\right ) + 3 \, {\left (\cosh \left (b x^{2} + a\right ) \cosh \left (a\right ) - \cosh \left (b x^{2} + a\right ) \sinh \left (a\right )\right )} \sinh \left (b x^{2} + a\right )^{2} + 3 \, {\left (\cosh \left (b x^{2} + a\right )^{2} \cosh \left (a\right ) - \cosh \left (b x^{2} + a\right )^{2} \sinh \left (a\right )\right )} \sinh \left (b x^{2} + a\right )\right )} \sqrt {b} \operatorname {erf}\left (\sqrt {b} x\right ) + 18 \, {\left (5 \, b x \cosh \left (b x^{2} + a\right )^{4} - 18 \, b x \cosh \left (b x^{2} + a\right )^{2} - 3 \, b x\right )} \sinh \left (b x^{2} + a\right )^{2} + 6 \, b x + 36 \, {\left (b x \cosh \left (b x^{2} + a\right )^{5} - 6 \, b x \cosh \left (b x^{2} + a\right )^{3} - 3 \, b x \cosh \left (b x^{2} + a\right )\right )} \sinh \left (b x^{2} + a\right )}{288 \, {\left (b^{2} \cosh \left (b x^{2} + a\right )^{3} + 3 \, b^{2} \cosh \left (b x^{2} + a\right )^{2} \sinh \left (b x^{2} + a\right ) + 3 \, b^{2} \cosh \left (b x^{2} + a\right ) \sinh \left (b x^{2} + a\right )^{2} + b^{2} \sinh \left (b x^{2} + a\right )^{3}\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int x^{2} \sinh ^{3}{\left (a + b x^{2} \right )}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.43, size = 166, normalized size = 1.04 \begin {gather*} \frac {\sqrt {3} \sqrt {\pi } \operatorname {erf}\left (-\sqrt {3} \sqrt {-b} x\right ) e^{\left (3 \, a\right )}}{288 \, \sqrt {-b} b} + \frac {\sqrt {3} \sqrt {\pi } \operatorname {erf}\left (-\sqrt {3} \sqrt {b} x\right ) e^{\left (-3 \, a\right )}}{288 \, b^{\frac {3}{2}}} + \frac {x e^{\left (3 \, b x^{2} + 3 \, a\right )}}{48 \, b} - \frac {3 \, x e^{\left (b x^{2} + a\right )}}{16 \, b} - \frac {3 \, x e^{\left (-b x^{2} - a\right )}}{16 \, b} + \frac {x e^{\left (-3 \, b x^{2} - 3 \, a\right )}}{48 \, b} - \frac {3 \, \sqrt {\pi } \operatorname {erf}\left (-\sqrt {b} x\right ) e^{\left (-a\right )}}{32 \, b^{\frac {3}{2}}} - \frac {3 \, \sqrt {\pi } \operatorname {erf}\left (-\sqrt {-b} x\right ) e^{a}}{32 \, \sqrt {-b} b} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int x^2\,{\mathrm {sinh}\left (b\,x^2+a\right )}^3 \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________